<?php
session_start();
$area = $_SESSION[area];
$default_area = $_SESSION[default_area];
if(!session_is_registered(login)){
    session_destroy();
    header("Location: ../index.php");
}

if($area != $default_area){
    session_destroy();
    header("Location: ../index.php");
}

?>
